//
//  PlacardBox.m
//  Rectiffy
//
//  Created by Jesper on 2007-07-14.
//  Copyright 2007 waffle software. All rights reserved.
//

#import "PlacardBox.h"


@implementation PlacardBox

- (id)initWithFrame:(NSRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        // Initialization code here.
    }
    return self;
}

- (BOOL)isOpaque {
	return YES;
}

- (void)drawRect:(NSRect)rect {
    if (!NSEqualSizes(rect.size,[self visibleRect].size)) { [self setNeedsDisplay:YES]; [self displayIfNeeded]; return; }
	[[NSColor controlColor] setFill];
	[[NSBezierPath bezierPathWithRect:rect] fill];
	[[[NSColor gridColor] colorWithAlphaComponent:0.6] setFill];
	[[NSBezierPath bezierPathWithRect:rect] fill];
	[[[NSColor gridColor] shadowWithLevel:0.3] setFill];
	[[NSBezierPath bezierPathWithRect:NSMakeRect(0.0,NSHeight(rect)-1.0,NSWidth(rect),1.0)] fill];
}

@end
